package http

import (
	"context"
	"github.com/go-kit/kit/endpoint"
)

func MakeOrderPayEndpoint(s OrderServiceHttpInterface) endpoint.Endpoint {
	return func(ctx context.Context, request interface{}) (response interface{}, err error) {
		order, err := s.Pay(ctx, 1, 2)
		if err != nil {
			return
		}

		return payResponse{
			Order: order,
		}, nil
	}
}
